package com.aplink.generic.pojo.controlspec.gridview;

import java.util.ArrayList;
import java.util.List;

import com.aplink.generic.pojo.ObjectFilter;
import com.aplink.generic.pojo.controlspec.ControlSpec;
import com.aplink.generic.util.ResourcesHelper;
import com.aplink.generic.util.objectrule.TargetRuleCollection;

public class GridViewSpec extends ControlSpec {
    /**
     * 
     */
    private static final long serialVersionUID = 6960774853477478889L;
    private String mContentData;
    private String mDataObject;
    private ObjectFilter mFilter;
    private List<GridViewItem> mGalleryItems;
    private String mRowItem;
    private String mRptrdesign;
    private TargetRuleCollection mTargetRuleCollection;

    public GridViewSpec() {
        this.mGalleryItems = new ArrayList<GridViewItem>();
    }

    public void add(final GridViewItem galleryItem) {
        this.mGalleryItems.add(galleryItem);
    }

    public String getContentData() {
        return this.mContentData;
    }

    public int getContentDataID() {
        return ResourcesHelper.getRawIdByName(this.mContentData);
    }

    @Override
    public String getDataObject() {
        return this.mDataObject;
    }

    public ObjectFilter getFilter() {
        return this.mFilter;
    }

    public List<GridViewItem> getGalleryItems() {
        return this.mGalleryItems;
    }

    public String getRowItem() {
        return this.mRowItem;
    }

    public String getRptrdesign() {
        return this.mRptrdesign;
    }

    public int getRptrdesignID() {
        return ResourcesHelper.getRawIdByName(this.mRptrdesign);
    }

    public TargetRuleCollection getTargetRuleCollection() {
        return this.mTargetRuleCollection;
    }

    public void setContentData(final String contentData) {
        this.mContentData = contentData;
    }

    @Override
    public void setDataObject(final String dataObject) {
        this.mDataObject = dataObject;
    }

    public void setFilter(final ObjectFilter filter) {
        this.mFilter = filter;
    }

    public void setGalleryItems(final List<GridViewItem> galleryItems) {
        this.mGalleryItems = galleryItems;
    }

    public void setRowItem(final String rowItem) {
        this.mRowItem = rowItem;
    }

    public void setRptrdesign(final String rptrdesign) {
        this.mRptrdesign = rptrdesign;
    }

    public void setTargetRuleCollection(
            final TargetRuleCollection targetRuleCollection) {
        this.mTargetRuleCollection = targetRuleCollection;
    }

}
